from coin.exchange.base.kr_rest.py_public_client import PyPublicClient


def generate_public_client(market_type, exchange, api_version):
  # in the order of exchange from coin_proto
  supported_markets = (
    ('Futures', 'Binance'),
    ('Futures', 'Bybit'),
    ('Futures', 'Dydx'),
    ('Futures', 'Ftx'),
    ('Futures', 'Huobi'),
    ('Futures', 'Okex'),
    ('Futures', 'Phemex'),
    ('Futures', 'Kucoin'),
    ('Futures', 'Deribit'),
    ('Spot', 'Binance'),
    ('Spot', 'Bitbank'),
    ('Spot', 'Bithumb'),
    ('Spot', 'Btcturk'),
    ('Spot', 'Bybit'),
    ('Spot', 'Ftx'),
    ('Spot', 'Gateio'),
    ('Spot', 'Gdax'),
    ('Spot', 'Huobi'),
    ('Spot', 'Korbit'),
    ('Spot', 'Kraken'),
    ('Spot', 'Kucoin'),
    ('Spot', 'Mexc'),
    ('Spot', 'Okex'),
    ('Spot', 'Upbit'),
    ('Spot', 'Phemex'),
    ('Options', 'Deribit')
  )
  market = (market_type, exchange)
  if market in supported_markets:
    return PyPublicClient()
  else:
    raise NotImplementedError(market)
